package org.monkey.request.plugin.handler;

import cn.hutool.json.JSONUtil;
import lombok.extern.slf4j.Slf4j;
import org.monkey.request.plugin.entity.RequestInfo;
import org.monkey.request.plugin.service.RequestLogAfterHandler;

@Slf4j
public class DefaultRequestLogAfterHandler implements RequestLogAfterHandler {



  @Override
  public void doAfter(RequestInfo requestInfo) {
    log.info("request out: url={},ip={}", requestInfo.getUrl(), requestInfo.getIp());
    log.info("whole request info:{}", JSONUtil.toJsonStr(requestInfo));
  }
}
